<?php

class Zend_View_Helper_FeedViewer
{
    function FeedViewer()
    {
        $output = '<div class="feedviewer">';
        
        $feed = new Zend_Feed_Atom('http://vifito.eu/index.php?format=feed&type=atom');
        foreach ($feed as $entry) {            
            $output .= '<div class="entry">' .
                '<a href="' . $entry->link('alternate') . '" target="news" ' .
                    'title="' . $entry->link('alternate') . '">' .
                    $entry->title() . '</a></div>';
        }
        
        $output .= '</div>';
        
        return $output;
    }
}